<div class="ciucourses index">
  <h2><?php __('Ciucourses');?></h2>
  
  <?php if(isset($language_list)){ ?>
  <?php 
    foreach($language_list as $key =>$val){
      echo "<div class='button'>";
      echo $this->Html->link(__($val, true), array('action' => 'index', $key));
      echo "</div>";
    }
  ?>
  <?php } ?>
  
  <?php if(isset($language_id)){ ?>
    <div class="button">
      <?php echo $this->Html->link(__('Add', true), array('action' => 'add' , $language_id)); ?>
    </div>
  <?php } ?>
  
  
  <table cellpadding="0" cellspacing="0">
  <tr>
      <th><?php echo $this->Paginator->sort('id');?></th>
      <th><?php echo $this->Paginator->sort('ciulanguage_id');?></th>
      <th><?php echo $this->Paginator->sort('ciulevel_id');?></th>
      <th><?php echo $this->Paginator->sort('ciutimetable_id');?></th>
      <th><?php echo $this->Paginator->sort('ciuroom_id');?></th>
      <th><?php echo $this->Paginator->sort('Teacher' );?></th>
      <th><?php echo $this->Paginator->sort('ciucoursestate_id');?></th>
      <th><?php echo $this->Paginator->sort('ciuacademicperiod_id');?></th>
      <th><?php echo $this->Paginator->sort('amount_students');?></th>
      <th class="actions"><?php __('Actions');?></th>
  </tr>
  <?php
  $i = 0;
  foreach ($ciucourses as $ciucourse):
    $class = null;
    if ($i++ % 2 == 0) {
      $class = ' class="altrow"';
    }
  ?>
  <tr<?php echo $class;?>>
    <td><?php echo $ciucourse['Ciucourse']['id']; ?>&nbsp;</td>
    <td>
      <?php echo $this->Html->link($ciucourse['Ciulanguage']['name'], array('controller' => 'ciulanguages', 'action' => 'view', $ciucourse['Ciulanguage']['id'])); ?>
    </td>
    <td>
      <?php echo $this->Html->link($ciucourse['Ciulevel']['name'], array('controller' => 'ciulevels', 'action' => 'view', $ciucourse['Ciulevel']['id'])); ?>
    </td>
    <td>
      <?php echo $this->Html->link($ciucourse['Ciutimetable']['name'], array('controller' => 'ciutimetables', 'action' => 'view', $ciucourse['Ciutimetable']['id'])); ?>
    </td>
    <td>
      <?php echo $this->Html->link($ciucourse['Ciuroom']['name'], array('controller' => 'ciurooms', 'action' => 'view', $ciucourse['Ciuroom']['id'])); ?>
    </td>
    <td>
      <?php echo $this->Html->link($ciucourse['Ciuuser']['name'], array('controller' => 'ciuusers', 'action' => 'view', $ciucourse['Ciuuser']['id'])); ?>
    </td>
    <td>
      <?php echo $this->Html->link($ciucourse['Ciucoursestate']['name'], array('controller' => 'ciucoursestates', 'action' => 'view', $ciucourse['Ciucoursestate']['id'])); ?>
    </td>
    <td>
      <?php echo $this->Html->link($ciucourse['Ciuacademicperiod']['name'], array('controller' => 'ciuacademicperiods', 'action' => 'view', $ciucourse['Ciuacademicperiod']['id'])); ?>
    </td>
    <td>
      <?php 00; ?>
    </td>
    <td class="actions">
      <?php echo $this->Html->link(__('Edit', true), array('action' => 'editapprove', $ciucourse['Ciucourse']['id'])); ?>
    </td>
  </tr>
<?php endforeach; ?>
  </table>
  <p>
  <?php
  echo $this->Paginator->counter(array(
  'format' => __('Page %page% of %pages%, showing %current% records out of %count% total, starting on record %start%, ending on %end%', true)
  ));
  ?>  </p>

  <div class="paging">
    <?php echo $this->Paginator->prev('<< ' . __('previous', true), array(), null, array('class'=>'disabled'));?>
   |  <?php echo $this->Paginator->numbers();?>
 |
    <?php echo $this->Paginator->next(__('next', true) . ' >>', array(), null, array('class' => 'disabled'));?>
  </div>
</div>



<div class="actions">
  <h3><?php __('Actions'); ?></h3>
  <ul>
    <li><?php echo $this->Html->link(__('List Ciulanguages', true), array('controller' => 'ciulanguages', 'action' => 'index')); ?> </li>
    <li><?php echo $this->Html->link(__('List Ciulevels', true), array('controller' => 'ciulevels', 'action' => 'index')); ?> </li>
    <li><?php echo $this->Html->link(__('List Ciutimetables', true), array('controller' => 'ciutimetables', 'action' => 'index')); ?> </li>
    <li><?php echo $this->Html->link(__('List Ciurooms', true), array('controller' => 'ciurooms', 'action' => 'index')); ?> </li>
    <li><?php echo $this->Html->link(__('List Ciucoursestates', true), array('controller' => 'ciucoursestates', 'action' => 'index')); ?> </li>
    <li><?php echo $this->Html->link(__('List Ciuacademicperiods', true), array('controller' => 'ciuacademicperiods', 'action' => 'index')); ?> </li>
  </ul>
</div>